Bus system and method of diagnosing subscribers interconnected via said bus-system

ABSTRACT

A diagnostic device and a diagnostic method for use with a bus system that includes stations interconnected over a bus, one station of which is set up as the master station and the other stations being slave stations. A diagnosis operation is performed which allows differentiated fault information to be obtained with regard to individual outputs of the stations, where the expenditure for the diagnostic device is low. The diagnosis is achieved by providing a diagnostic device only in the master station, by storing voltage and/or current information on at least one output of at least one slave station to be diagnosed in the diagnostic device, and by performing the diagnosis of the outputs under preselected or preselectable conditions on the basis of a program stored in the master station.

BACKGROUND INFORMATION

The present invention relates to a bus system with stationsinterconnected over a bus, one station of which is set up as a masterand the other stations being set up as slaves, with a diagnostic deviceand a method of diagnosing stations interconnected over a bus system,one station of which is set up as a master with the other stationsfunctioning as slaves.

A known bus system and method are described in International Patent No.WO 90/09631. With this known bus system and method, functioning of thedata bus and/or functioning of the stations is monitored with the helpof fault detection signals in the form of watchdog signals, and in theevent of a fault, defined emergency operation modes are initiated, withtwo different emergency operation modes being implementable. With thisfault detection method, signals are periodically sent and receivedrepeatedly, with the stations participating in bus traffic expecting theexternal fault detection signals within a predetermined time reference.This does not provide for any further fault diagnosis.

SUMMARY OF THE INVENTION

An object of the present invention is to make available a bus systemhaving a plurality of stations and a method of the for diagnosing theoutputs of the stations.

According to the present invention, the bus system is designed so that adiagnostic device is provided only in the master; current and/or voltageinformation from at least one output of at least one slave to bediagnosed is stored in the diagnostic device, and diagnosis of theoutputs can be performed under preselected and preselectable conditionson the basis of a program stored in the master.

This method provides for the diagnostic device to have a short-circuitdetecting device and an interrupt detection device and for a diagnosticmode to be started for diagnosis at a preselectable time, for theoutputs of all slaves to be switched to preselected states according toa program present in the master, and for the outputs that are to bediagnosed to be queried in succession with regard to a short-circuit oran interrupt in the preselected states, with the diagnosis beingperformed in the master.

With these measures, diagnosis of the stations with regard to variousfaults can be performed with a simple setup, so that information on thetype of fault can be derived and fault strategies aimed at the giventype of fault can be implemented. In the entire bus system, theexpenditure for the diagnostic device and the related costs fall dueonly once for the master.

If it is provided that the bus system with the stations and theiroutputs can be switched into a defined state for diagnosis of ashort-circuit or an interrupt, with the current or voltage stateprevailing at the output to be diagnosed being detectable and thatdiagnosis can be performed on the basis of the stored current and/orvoltage information and the detected current or voltage state, thendifferentiated information regarding whether a short-circuit or aninterrupt has been detected at a respective output can be obtained. Theinformation stored in the diagnostic device makes it possible todetermine the extent of a short-circuit or an interrupt and tocoordinate an appropriate fault strategy. For example, it is possible toascertain in this way whether only part of a winding of a stepping motoris defective.

The diagnostic measures can be performed to advantage with a setupwhereby the diagnostic device has a reversible resistance device and/ora reversible measuring amplifier.

According to the present invention, if all stations are run into thelowest power consumption state after the start of the diagnostic mode,with a change in state of the stations being prevented except for theoutput to be diagnosed, then a definite state of the bus system prevailsfor performing the diagnosis, so that faults can be detected reliably.

The procedure is advantageous in that the current measurement range of adiagnostic device provided in the master for detecting a short-circuitis set as large as possible and the gain is set as low as possible; thenthe output to be diagnosed in a slave is turned on, and if a set currentfor this output is exceeded, a short-circuit is diagnosed. With thesemeasures, the diagnostic device is protected from the risk of damage inthe event a short-circuit actually occurs and the high current occurringwith it, while the measurement range can then be reduced to detect anincomplete short-circuit.

A sensitivity suitable for detection of an interrupt is achieved, withthe sensitivity for detection of different interrupt degrees beingincrementally adjustable. If there are also provisions so that thecurrent measurement range in the master is reduced or the gain isincreased to detect an interrupt, then the output to be diagnosed isdisconnected and an interrupt is diagnosed if the signal detected isbelow a specified smallest current change.

Furthermore, a systematic diagnosis of the outputs to be tested forshort-circuit and interrupt is made possible if the procedure is suchthat the short-circuit diagnosis and the interrupt diagnosis areperformed in succession in this order at all outputs to be diagnosed.The interrupt diagnosis is performed only when no short-circuit haspreviously been diagnosed at the same output, and the diagnosis isconcluded when all the outputs to be diagnosed have been tested.

In the event a fault is detected, the measures are advantageous in thata fault entry is made when a short-circuit is detected in the diagnosticdevice and a programmed short-circuit strategy is performed, and if aninterrupt is detected in the diagnostic device, a fault entry and aprogrammed interrupt strategy are implemented.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 shows a bus system according to the present invention thatincludes a plurality of stations connected.

FIG. 2 shows a flow chart representing a method for diagnosing the bussystem of the present invention.

DETAILED DESCRIPTION

The bus system illustrated in FIG. 1 has a bus with a data line D and abus power supply V+, V−. A master 1 and slaves 2, 3, 4 are connected tothe bus as stations.

A diagnostic device 5 for stations 1, 2, 3, 4 is provided in master 1.As shown in FIG. 1, a selectable number n of slaves may be provided inaccordance with the physical possibilities of the bus system.

The diagnostic device is represented symbolically as a resistor, whichis to be understood to refer to a suitable measuring device with asuitable resistance arrangement or a measuring amplifier. Diagnosticdevice 5 also has an analog-to-digital converter (not shown). Diagnosticdevice 5 is also designed for detecting short-circuits and/or interruptsat some or all outputs of some or all slaves, for which purposediagnostic device 5 is equipped with a means for measuring currentand/or voltage.

FIG. 2 shows a flow chart for a diagnosis. After a start 10, all slaves2, 3, 4 are put in a state of lowest possible power consumption by aprogram or protocol in step 11 to permit the greatest possible currentresolution. A change in the states of the bus system is suppressed inthe diagnostic mode selected in this way. Only the respective output tobe tested can be switched. In this state of the lowest possible powerconsumption, the total power consumption of the bus is constant, e.g.,in a range between 150 mA and 250 mA. The diagnostic device knows thisvalue. Under these defined output conditions, a short-circuit orinterrupt diagnosis of actuators (e.g., switch outputs, motor windings,etc.) can be performed reliably.

To perform the short-circuit diagnosis, the largest possible measurementrange or the lowest possible gain is selected in step 12 in thediagnostic device. In step 13, master 1 activates precisely one output,whose address is also stored in master 1, in precisely one slave. If aspecified current is exceeded, a short-circuit is diagnosed in step 14,because a regular current of the respective output is also stored indiagnostic device 5. If the current when the bus is idle is 200 mA andthe regular current at the respective output, e.g., a stepping motorwinding, is 250 mA, specified current I_(Ref) can be set much higherthan the sum of the zero-signal current and the regular current, e.g.,800 mA.

With specified stepped current values and incrementally reduced currentmeasurement ranges or incrementally increased gain, the extent of theshort-circuit can be determined more specifically. If it is found instep 14 that specified current I_(Ref) is exceeded, a short-circuit isdiagnosed in step 14.1. Then in step 14.2, a fault is entered and, ifdesired, suitable short-circuit strategies are implemented. For example,if only a partial short-circuit is diagnosed instead of a complete one,the respective output of the respective slave can be operated for ashorter period of time and/or at a lower power in longer intervals.

If the diagnosis shows in step 14 that specified current I_(Ref) has notbeen exceeded, and if multiple current measurement ranges or gain levelsare being processed, then in step 15 an interrupt diagnosis is performedon the same output and the current measurement range is reduced or thegain is increased in diagnostic device 5. The output activated duringthe short-circuit diagnosis is disconnected. If the current is below aspecified least current change ΔI_(Refmin) in step 16, an interrupt isdiagnosed. Least current change ΔI_(Refmin) and the regular current atthe respective disconnected, fault-free input are also known indiagnostic device 5, so that the current change due to the interrupt isdetected. Here again, more precise measurements of the extent of theinterrupt can be made by gradation of the current measurement ranges andthe gain level.

If an interrupt is diagnosed, i.e., the current is below the leastspecified current change I_(Refmin), then after step 16.1, where theinterrupt is diagnosed, a fault entry is made in step 16.2 andoptionally a desired interrupt strategy is implemented; this can also beselected according to the extent of the interrupt.

In any case, i.e., when a short-circuit or an interrupt or no fault isdetected, the diagnostic procedure is restarted in step 17, until allthe outputs to be tested have been processed.

Then the diagnosis is concluded in step 18.

Suitable situations where the diagnostic mode is carried out include,for example, start-up of the bus system, before shutdown of the bussystem or a test situation in a workshop or by service personnel. If afault occurs in the bus system, it may also be advantageous for thediagnostic mode to be initiated by a selected program.

On the basis of the faults registered, it is also possible to ascertainover a period of time whether a short-circuit or an interrupt iscontinuous or just a transient occurrence.

The bus system and diagnostic method described here can be used toadvantage in motor vehicles.

What is claimed is:
 1. A bus system, comprising: a bus; a plurality ofslave stations coupled to the bus; and a master station coupled to thebus and including a diagnostic device for storing at least one ofcurrent information and voltage information from at least one output ofat least one of the plurality of slave stations to be diagnosed,wherein: the master station stores a program for performing a diagnosisof the at least one output to be diagnosed under a plurality ofpreselected conditions, the diagnostic device detects at least one of ashort-circuit and an interrupt at at least a subset of outputs of atleast a subset of the plurality of slave stations in order to perform adiagnosis of the at least one of the short-circuit and the interrupt,each output of the master station and of the plurality of slave stationsis switchable to a defined state in which a voltage state and a currentstate of the at least one output to be diagnosed can be detected, andthe diagnosis is performed as a function of at least one of the storedcurrent information and the stored voltage information, and as afunction of one of the detected voltage state and the detected currentstate; wherein the diagnosis is performed after the master station andeach one of the plurality of slave stations are switched to a lowestpower consumption state.
 2. A bus system, comprising: a bus; aplurality, of slave stations coupled to the bus; and a master stationcoupled to the bus and including a diagnostic device for storing atleast one of current information and voltage information from at leastone output of at least one of the plurality of slave stations to bediagnosed, wherein: the master station stores a program for performing adiagnosis of the at leas;t one output to be diagnosed under a pluralityof preselected conditions, the diagnostic device detects at least one ofa short-circuit and an interrupt at at least a subset of outputs of atleast a subset of the plurality of slave stations in order to perform adiagnosis of the at least one of the short-circuit and the interrupt,each output of the master station and of the plurality of slave stationsis switchable to a defined state in which a voltage state and a currentstate of the at least one output to be diagnosed can be detected, andthe diagnosis is performed as a function of at least one of the storedcurrent information and the stored voltage information, and as afunction of one of the detected voltage state and the detected currentstate; wherein the diagnostic device includes at least one of areversible measuring resistor device and a reversible measuringamplifier.
 3. A method for causing a master station coupled to a bus toperform a diagnosis on a plurality of slave stations coupled to the bus,comprising the steps of: providing a diagnostic mode for the diagnosisat a preselected time; switching an output of each one of the pluralityof slave stations to one of a plurality of preselected states accordingto a program stored in the master station; adjusting a gain of thediagnostic device to a value appropriate for diagnosing one of ashort-circuit and an interrupt; for at least one of the plurality ofpreselected states, querying in succession each output of the pluralityof slave stations to be diagnosed with respect to one of a short-circuitand an interrupt by detecting one of a current state and a voltage statepresent at each output to be diagnosed; and performing the diagnosis asa function of at least one of stored current information and storedvoltage information and as a function of one of the detected currentstate and the detected voltage state.
 4. The method according to claim3, further comprising the steps of: performing one of (a) and (b): (a)setting a current measurement range of a diagnostic device provided inthe master station for detecting a short-circuit to a large-as-possiblevalue; (b) setting a gain of the diagnostic device to a low-as-possiblevalue; activating the output to be diagnosed; and diagnosing the outputto be diagnosed as exhibiting the short-circuit if a current specifiedfor the output to be diagnosed is exceeded by a current detected at theoutput to be diagnosed.
 5. The method according to claim 3, wherein inorder to detect the interrupt, the method further comprises the stepsof: performing one of (a) and (b): (a) reducing a current measurementrange of the master station; (b) increasing a gain of the masterstation; disconnecting the output to be diagnosed; and diagnosing theinterrupt if a change in a current of the output to be diagnosed isbelow a specified current change minimum value.
 6. The method accordingto claim 3, further comprising the steps of: performing a short-circuitdiagnosis for each output of the plurality of slave stations; for eachoutput of the plurality of slave stations, performing an interruptdiagnosis in succession with respect to a previously performedshort-circuit diagnosis only if the previously performed short-circuitdiagnosis did not detect the short-circuit; and terminating each one ofthe short-circuit diagnosis and the interrupt diagnosis after the outputof each slave station has been tested.
 7. The method according to claim3, further comprising the steps of: when the short-circuit is detectedby a diagnostic device of the master station, registering a fault andexecuting a programmed short-circuit strategy; and when the interrupt isdetected by the diagnostic device, registering the fault and executing aprogrammed interrupt strategy.
 8. A method for causing a master stationcoupled to a bus to perform a diagnosis on a plurality of slave stationscoupled to the bus, comprising the steps of: providing a diagnostic modefor the diagnosis at a preselected time; switching an output of each oneof the plurality of slave stations to one of a plurality of preselectedstates according to a program stored in the master station; for at leastone of the plurality of preselected states, querying in succession eachoutput of the plurality of slave stations to be diagnosed with respectto one of a short-circuit and an interrupt by detecting one of a currentstate arid a voltage state present at each output to be diagnosed; andperforming the diagnosis as a function of at least one of stored currentinformation and stored voltage information and as a function of one ofthe detected current state and the detected voltage state; wherein,after a start of the diagnostic mode, the method further comprises thesteps of: switching the master station and each one of the plurality ofslave stations to a lowest power consumption state; and preventing achange in a state of the master station and each one of the plurality ofslave stations except for the output to be diagnosed.
 9. A method forcausing a master station coupled to a bus to perform a diagnosis on aplurality of slave stations coupled to the bus, comprising the steps of:providing a diagnostic mode for the diagnosis at a preselected time;switching an output of each one of the plurality of slave stations toone of a plurality of preselected states according to a program storedin the master station; switching the master station and each one of theplurality of slave stations to a lowest power consumption state; for atleast one of the plurality of preselected states, querying in successioneach output of the plurality of slave stations to be diagnosed withrespect to one of a short-circuit and an interrupt by detecting one of acurrent state and a voltage state present at each output to bediagnosed; and performing the diagnosis as a function of at least one ofstored current information and stored voltage information and as afunction of one of the detected current state and the detected voltagestate.
 10. A bus system, comprising: a bus including a bus power supply;and a plurality of stations interconnected by the bus and coupled to thebus power supply, one station of the plurality of stations beingconfigured as a master, further stations being configured as slaves, themaster storing a program and having a diagnostic device coupled to thebus power supply, the diagnostic device storing at least one of currentand voltage information from at least one diagnosed output of at leastone slave and detecting at least one of a voltage state and a currentstate present at the diagnosed output that is supplied by the bus powersupply, the diagnosis being conductible under specified or specifiableconditions on the basis of the program stored in the master, thediagnosis also being based on the stored at least one of current andvoltage information and the detected at least one of current state andvoltage state; wherein the slaves can be switched into a defined statefor diagnosis of one of a short-circuit and an interruption in theslaves, the diagnosed output and the outputs that are switched into adefined state being connected to the bus power supply.
 11. A method fordiagnosing a plurality of stations of a bus system interconnected by abus having a bus power supply, of which one of the plurality of stationsis configured as a master having a program, and further stations areconfigured as slaves, each slave having an output coupled to the buspower supply, the method comprising: initiating a diagnosis operatingmode at the master at a specified or specifiable time; switching theoutputs of all slaves coupled to the bus power supply into specifiedstates according to tie program in the master; querying the outputs ofthe slaves in the specified states in succession with regard to one of ashort-circuit and an interruption in the slaves; storing in the masterat least one of current and voltage information regarding the outputs ofthe slaves; detecting one of a current or voltage value present at adiagnosed output supplied by the bus power supply; and diagnosing thediagnosed output on the basis of the stored information current and thedetected at least one of current and voltage state.